//
//  BluetoothLogable.swift
//  Nexs
//  日志接口
//
//  Created by roni on 2025/7/28.
//

// swiftlint:disable function_parameter_count
public protocol BluetoothLogable {
    func log(_ msg: String, logLevel: Int32, file: String, function: String, line: Int, fileId: String)
}

extension BluetoothLogable {
    func log(_ msg: String, logLevel: Int32 = 2, file: String = #file, function: String = #function, line: Int = #line, fileId: String = #fileID) {
        self.log(msg, logLevel: logLevel, file: file, function: function, line: line, fileId: fileId)
   }
}

public struct BluetoothCentralLogger: BluetoothLogable {
    public init() {}
    
    public func log(_ msg: String, logLevel: Int32, file: String, function: String, line: Int, fileId: String) {
//        swiftXLog("BLE.Central: - " + msg, logLevel: logLevel, file: file, function: function, line: line, fileId: fileId)
    }
}

public struct BluetoothFreetalkieLogger: BluetoothLogable {
    public init() {}
    
    public func log(_ msg: String, logLevel: Int32, file: String, function: String, line: Int, fileId: String) {
//        swiftXLog("BLE.Central.freetalkie: - " + msg, logLevel: logLevel, file: file, function: function, line: line, fileId: fileId)
    }
}

public struct BluetoothScannerLogger: BluetoothLogable {
    public init() {}
    
    public func log(_ msg: String, logLevel: Int32, file: String, function: String, line: Int, fileId: String) {
//        swiftXLog("BLE.Scanner: - " + msg, logLevel: logLevel, file: file, function: function, line: line, fileId: fileId)
    }
}

public struct BluetoothPeripheralLogger: BluetoothLogable {
    public init() {}
    
    public func log(_ msg: String, logLevel: Int32, file: String, function: String, line: Int, fileId: String) {
//        swiftXLog("BLE.Peripheral: - " + msg, logLevel: logLevel, file: file, function: function, line: line, fileId: fileId)
    }
}

// swiftlint:enable function_parameter_count
